<?php if( !defined( '_VALID_MOS' ) && !defined( '_JEXEC' ) ) die( 'Direct Access to '.basename(__FILE__).' is not allowed.' );

mm_showMyFileName( __FILE__ );

/*echo "<pre>";
var_dump($_SESSION["cart"]);
echo "</pre>";*/
$cart = @$_SESSION["cart"];

$db =& JFactory::getDBO();

$q = "SELECT * FROM #__vm_category WHERE `category_publish` = 'Y'";
$db = JFactory::getDBO();
$db->setQuery($q);
$category = $db->loadObjectList();
$category_id = @JRequest::getInt("category_id",$category[0]->category_id);
$subtotal = 0;
$shipping = 0;
$total = 0;
$tpl = vmTemplate::getInstance();

$flypage = "shop.delivery.tpl";
$tpl->set("category_id",@$category_id);
$tpl->set("category",@$category);
$tpl->set("cart",@$cart);
$tpl->set("subtotal",@$subtotal);
$tpl->set("shipping",@$shipping);
$tpl->set("total",@$total);
echo $tpl->fetch( '/pages/'.$flypage . '.php' );
?>